#ifndef MAINWINDOW_H
#define MAINWINDOW_H

#include <QtGui/QMainWindow>
#include "sqlconsole.h"
#include "changeuserdialog.h"


namespace Ui {
    class MainWindow;
}

class MainWindow : public QMainWindow {
    Q_OBJECT
public:
    MainWindow(QWidget *parent = 0);
    ~MainWindow();

protected:
    void changeEvent(QEvent *e);

private:
    Ui::MainWindow *m_ui;
    ChangeUserDialog changeUserDialog;
    void closeEvent(QCloseEvent *event);
private slots:

    //menu file
    void on_actPreferences_triggered();
    void on_actExit_triggered();
    void on_actUserControl_triggered();
    void on_actChangeUser_triggered();

    //menu Dicts
    void on_actDictTypeOfTV_triggered();
    void on_actDictTypeOfDTP_triggered();
    void on_actDictDistricts_triggered();
    void on_actDictRoads_triggered();
    void on_actDictStreets_triggered();

    //menu Rept
    void on_actDiagramAffect_triggered();
    void on_actDiagramAffect2_triggered();

    //menu Service
    void on_actSqlConsole_triggered();

    //menu About
    void on_actAboutQt_triggered();
    void on_actAboutProgram_triggered();
public slots:
    void setPermissionsOnGui();
signals:
    void userChanged();
};

#endif // MAINWINDOW_H
